<?php

namespace core\lib\upload;

use app\bll\SyscnfUpload as BllSyscnfUpload;

class UploadImage extends UploadBase
{

    public function __construct(string $path = '', $ispublic = true)
    {
        $bllSyscnfUpload = new BllSyscnfUpload();
        $uploadcnf = $bllSyscnfUpload->find();
        parent::__construct(
            ext: $uploadcnf['imageext'],
            size: $uploadcnf['imagesize'] * 1024 * 1024,
            ispublic: $ispublic,
            path: $path
        );
    }
}
